home *** CD-ROM | disk | FTP | other *** search
- property pStepframe, pMasterCount, pCurrentCount, pDownLoadsMasterCount, pDownLoadsCount, pImagesMasterCount, pImagesCount, pFlashPaperMasterCount, pFlashPaperCount, pFlashObject, pDirectorToFlashFinished, pMasterList, pmode
- global gRecordSet, gTracker, gMaster
-
- on new me
- pMasterList = []
- pDirectorToFlashFinished = "no"
- pStepframe = "none"
- pmode = "none"
- pMasterCount = 0
- pCurrentCount = 0
- pDownLoadsMasterCount = 0
- pImagesMasterCount = 0
- pDownLoadsCount = 0
- pImagesCount = 0
- pFlashPaperCount = 0
- pFlashPaperMasterCount = 0
- return me
- end
-
- on stepFrame me
- case pmode of
- "none":
- "storedData":
- case pStepframe of
- "none":
- nothing()
- "general":
- put "general started: " & "count is: " & pCurrentCount
- gRecordSet.mAddGeneralStored(gRecordSet.pCurrentCount)
- pStepframe = "Sections"
- "Sections":
- put "Sections started: " & "count is: " & pCurrentCount
- gRecordSet.mAddSectionsStored(gRecordSet.pCurrentCount)
- pStepframe = "DownLoads"
- "DownLoads":
- put "DownLoads started: " & "count is: " & pCurrentCount
- pDownLoadsMasterCount = gRecordSet.pMasterList[gRecordSet.pCurrentCount][3].count
- if pDownLoadsMasterCount = 0 then
- pStepframe = "Images"
- else
- pDownLoadsCount = 1
- me.mAddDownLoadsStored(pDownLoadsCount, gRecordSet.pCurrentCount)
- end if
- "IsDownLoadsFinished":
- put "IsDownLoadsFinished started: " & "count is: " & pCurrentCount
- pDownLoadsCount = pDownLoadsCount + 1
- if pDownLoadsCount > pDownLoadsMasterCount then
- pStepframe = "Images"
- else
- me.mAddDownLoadsStored(pDownLoadsCount, gRecordSet.pCurrentCount)
- end if
- "Images":
- put "Images started: " & "count is: " & pCurrentCount
- pImagesMasterCount = gRecordSet.pMasterList[gRecordSet.pCurrentCount][4].count
- if pImagesMasterCount = 0 then
- pStepframe = "FlashPaper"
- else
- pImagesCount = 1
- me.mAddImagesStored(pImagesCount, gRecordSet.pCurrentCount)
- end if
- "IsImagesFinished":
- put "IsImagesFinished started: " & "count is: " & pCurrentCount
- pImagesCount = pImagesCount + 1
- if pImagesCount > pImagesMasterCount then
- pStepframe = "FlashPaper"
- else
- me.mAddImagesStored(pImagesCount, gRecordSet.pCurrentCount)
- end if
- "FlashPaper":
- put "FlashPaper started: " & "count is: " & pCurrentCount
- pFlashPaperMasterCount = gRecordSet.pMasterList[gRecordSet.pCurrentCount][5].count
- if pFlashPaperMasterCount = 0 then
- pStepframe = "sendColdFusion"
- else
- pFlashPaperCount = 1
- me.mAddFlashPaperStored(pFlashPaperCount, gRecordSet.pCurrentCount)
- end if
- "IsFlashPaperFinished":
- put "IsFlashPaperFinished started: " & "count is: " & pCurrentCount
- pFlashPaperCount = pFlashPaperCount + 1
- if pFlashPaperCount > pFlashPaperMasterCount then
- pStepframe = "sendColdFusion"
- else
- me.mAddFlashPaperStored(pFlashPaperCount, gRecordSet.pCurrentCount)
- end if
- "sendColdFusion":
- put "sendColdFusion started: " & "count is: " & pCurrentCount
- gRecordSet.mSendToColdFusion()
- pStepframe = "wrapUp"
- "wrapUp":
- put "wrapUp started: " & "count is: " & pCurrentCount
- pCurrentCount = pCurrentCount + 1
- if pCurrentCount > pMasterCount then
- pStepframe = "CompleteWrapUp"
- else
- pStepframe = "general"
- pFlashObject.mReSetArrays()
- end if
- "CompleteWrapUp":
- pStepframe = "none"
- pmode = "none"
- gTracker.mDeleteFileFromFolder()
- end case
- "currentData":
- case pStepframe of
- "none":
- nothing()
- "general":
- put "general started"
- mAddGeneral()
- pStepframe = "Sections"
- "Sections":
- put "Sections started"
- mAddSections()
- pStepframe = "DownLoads"
- "DownLoads":
- put "DownLoads started"
- pDownLoadsMasterCount = gTracker.pDownLoadList.count
- if pDownLoadsMasterCount = 0 then
- pStepframe = "Images"
- else
- pDownLoadsCount = 1
- me.mAddDownLoads(pDownLoadsCount)
- end if
- "IsDownLoadsFinished":
- put "IsDownLoadsFinished started"
- pDownLoadsCount = pDownLoadsCount + 1
- if pDownLoadsCount > pDownLoadsMasterCount then
- pStepframe = "Images"
- else
- me.mAddDownLoads(pDownLoadsCount)
- end if
- "Images":
- put "Images started"
- pImagesMasterCount = gTracker.pPhotoViewList.count
- if pImagesMasterCount = 0 then
- pStepframe = "FlashPaper"
- else
- pImagesCount = 1
- me.mAddImages(pImagesCount)
- end if
- "IsImagesFinished":
- put "IsImagesFinished started"
- pImagesCount = pImagesCount + 1
- if pImagesCount > pImagesMasterCount then
- pStepframe = "FlashPaper"
- else
- me.mAddImages(pImagesCount)
- end if
- "FlashPaper":
- put "FlashPaper started"
- pFlashPaperMasterCount = gTracker.pFlashPaperViewList.count
- if pFlashPaperMasterCount = 0 then
- pStepframe = "wrapUp"
- else
- pFlashPaperCount = 1
- me.mAddFlashPaper(pFlashPaperCount)
- end if
- "IsFlashPaperFinished":
- put "IsFlashPaperFinished started"
- pFlashPaperCount = pFlashPaperCount + 1
- if pFlashPaperCount > pFlashPaperMasterCount then
- pStepframe = "wrapUp"
- else
- me.mAddFlashPaper(pFlashPaperCount)
- end if
- "wrapUp":
- put "wrapUp started"
- gRecordSet.mSendToColdFusion()
- pStepframe = "none"
- pmode = "none"
- pDirectorToFlashFinished = "yes"
- end case
- end case
- end
-
- on mProcessCurrentRecordSet me
- pFlashObject.mReSetArrays()
- pDirectorToFlashFinished = "no"
- pMasterCount = 1
- pmode = "currentData"
- pStepframe = "general"
- mDeleteActor(me)
- mAddActor(me)
- end
-
- on mProcessStoredRecordSet me
- gRecordSet.pFlashObject.mReSetArrays()
- pDirectorToFlashFinished = "no"
- gRecordSet.pMasterCount = gRecordSet.pMasterList.count
- pmode = "storedData"
- pCurrentCount = 1
- pStepframe = "general"
- mDeleteActor(me)
- mAddActor(me)
- end
-
- on mOneRecordSet me
- pMasterCount = 1
- end
-
- on mMoreRecordSets me, vCount
- pMasterCount = vCount
- end
-
- on mAddGeneral me
- a = gTracker.pGeneralList.sessionID
- b = gMaster.pGeneralSettings.presskitid
- c = gTracker.pGeneralList.startDateTime
- d = gTracker.pGeneralList.endDateTime
- e = gTracker.pGeneralList.screenheight
- f = gTracker.pGeneralList.screenwidth
- g = gTracker.pGeneralList.screendepth
- h = gTracker.pGeneralList.platform
- pFlashObject.mAddGeneral(a, b, c, d, e, f, g, h)
- end
-
- on mAddGeneralStored me, vListNumber
- a = gRecordSet.pMasterList[vListNumber][1].sessionID
- b = gRecordSet.pMasterList[vListNumber][1].pkID
- c = gRecordSet.pMasterList[vListNumber][1].startDateTime
- d = gRecordSet.pMasterList[vListNumber][1].endDateTime
- e = gRecordSet.pMasterList[vListNumber][1].screenheight
- f = gRecordSet.pMasterList[vListNumber][1].screenwidth
- g = gRecordSet.pMasterList[vListNumber][1].screendepth
- h = gRecordSet.pMasterList[vListNumber][1].platform
- pFlashObject.mAddGeneral(a, b, c, d, e, f, g, h)
- end
-
- on mAddSections me
- a = gTracker.pSectionList.main
- b = gTracker.pSectionList.first
- c = gTracker.pSectionList.gallery
- d = gTracker.pSectionList.slideshow
- e = gTracker.pSectionList.trailer
- f = gTracker.pSectionList.poster
- g = gTracker.pSectionList.logos
- h = gTracker.pSectionList.notes
- i = gTracker.pSectionList.summary
- j = gTracker.pSectionList.flashpaper
- k = gTracker.pSectionList.website
- pFlashObject.mAddSection(a, b, c, d, e, f, g, h, i, j, k)
- end
-
- on mAddSectionsStored me, vListNumber
- a = gRecordSet.pMasterList[vListNumber][2].main
- b = gRecordSet.pMasterList[vListNumber][2].first
- c = gRecordSet.pMasterList[vListNumber][2].gallery
- d = gRecordSet.pMasterList[vListNumber][2].slideshow
- e = gRecordSet.pMasterList[vListNumber][2].trailer
- f = gRecordSet.pMasterList[vListNumber][2].poster
- g = gRecordSet.pMasterList[vListNumber][2].logos
- h = gRecordSet.pMasterList[vListNumber][2].notes
- i = gRecordSet.pMasterList[vListNumber][2].summary
- j = gRecordSet.pMasterList[vListNumber][2].flashpaper
- k = gRecordSet.pMasterList[vListNumber][2].website
- pFlashObject.mAddSection(a, b, c, d, e, f, g, h, i, j, k)
- end
-
- on mAddDownLoads me, vCount
- a = gTracker.pDownLoadList[vCount][1]
- b = gTracker.pDownLoadList[vCount][2]
- pFlashObject.mAddDownLoads(a, b)
- pStepframe = "IsDownLoadsFinished"
- end
-
- on mAddDownLoadsStored me, vCount, vListNumber
- a = gRecordSet.pMasterList[vListNumber][3][vCount][1]
- b = gRecordSet.pMasterList[vListNumber][3][vCount][2]
- pFlashObject.mAddDownLoads(a, b)
- pStepframe = "IsDownLoadsFinished"
- end
-
- on mAddImages me, vCount
- a = gTracker.pPhotoViewList[vCount]
- pFlashObject.mAddImages(a)
- pStepframe = "IsImagesFinished"
- end
-
- on mAddImagesStored me, vCount, vListNumber
- a = gRecordSet.pMasterList[vListNumber][4][vCount]
- pFlashObject.mAddImages(a)
- pStepframe = "IsImagesFinished"
- end
-
- on mAddFlashPaper me, vCount
- a = gTracker.pFlashPaperViewList[vCount]
- pFlashObject.mAddFlashPaper(a)
- pStepframe = "IsFlashPaperFinished"
- end
-
- on mAddFlashPaperStored me, vCount, vListNumber
- a = gRecordSet.pMasterList[vListNumber][5][vCount]
- pFlashObject.mAddFlashPaper(a)
- pStepframe = "IsFlashPaperFinished"
- end
-
- on mSendToColdFusion me
- pFlashObject.mSendNewToColdFusion()
- end
-
- on mAddActor me
- add(the actorList, me)
- end
-
- on mDeleteActor me
- where = getOne(the actorList, me)
- if where > 0 then
- deleteAt(the actorList, where)
- end if
- end
-